// Copyright (c) 2016 Juan Delgado (JuDelCo)
// License: MIT License
// MIT License web page: https://opensource.org/licenses/MIT

#pragma once
#include "../CommonLib/IDGenerater.hpp"
namespace EntitasPP
{
	class IComponent
	{
		friend class Entity;
	public:
		long GetID() { return mInstanceID; }
		__declspec(property(get = GetID, put = SetID)) long InstanceID;
	protected:
		long mInstanceID;

		void SetID(long value) { this->mInstanceID = value; }
		IComponent() {
			this->InstanceID = IDGenerater::GenerateID();
		};
	};
}
